home *** CD-ROM | disk | FTP | other *** search
/ The Ultimate Guide to Advanture Travel / The Ultimate Guide to Advanture Travel.iso / pc / installa.6 / Online Files / Check Speed < prev    next >
Text File  |  1995-07-10  |  8KB  |  292 lines

  1. !*****************************************************************************
  2. !   C O P Y R I G H T   A N D   C O N F I D E N T I A L I T Y   N O T I C E
  3. !*****************************************************************************
  4. !
  5. !      Copyright © 1987-1994 America Online, Inc.  All rights reserved.
  6. !      This software contains valuable confidential and proprietary
  7. !      information of America Online, Inc. and is subject to applicable
  8. !      licensing agreements.  Unauthorized reproduction, transmission or
  9. !      distribution of this file and its contents is a violation of
  10. !      applicable laws.
  11. !
  12. !            A M E R I C A   O N L I N E   C O N F I D E N T I A L
  13. !
  14. !*****************************************************************************
  15.  
  16. ! --------------------------------------------------------------------
  17. !   YO-YO MODEM.ALCL
  18. !   By: David Steinberg
  19. !  
  20. !   Date: June 20, 1989
  21. !   Changed 8/8/89 By DMC to match on "OK" after AT command
  22. !   Changed 1/1/91 By DMC to not require "OK" reply to "+++" command
  23. !   Rev: 1.00
  24. !   Changed 3/2/93 to remove match numbers from MatchStr statements
  25. !----------------------------------------------------------------------
  26. !
  27. ! Connect Sequence:
  28. !
  29. -LABEL 0
  30. CheckPort "30"
  31. DsplyMsg "Verifying Modem Setup"
  32. CanBtn "30"               { if cancel button - just exit }
  33. SetTries 0
  34. ChrDelay 2
  35. !
  36. ! For now, start test at 2400 bps.
  37. !
  38. Jump "11"
  39. !
  40. !----------------------------------------------------------------------
  41. ! Check at 9600 Baud first.
  42. !
  43. -LABEL 1                { wake up the modem }
  44. !
  45. SerReset 9600 0 8 1
  46. Pause 30
  47. Flush
  48. !
  49. !                         
  50. ClrMchStr
  51. MatchStr "2" "OK"
  52. MatchStr "2" "NO"         
  53. MatchStr "2" "ERROR"      
  54. MatchStr "2" ">"          { Special case for Avatex 1200 modems}
  55. MatchStr "2" "+++"          
  56. !
  57. Pause 210               { Pause for 2 sec min gap }
  58. Xmit "+++"                { Get the modems attention}
  59. Wait 210                { Pause for 2 sec min gap }
  60. !
  61. -Label 2
  62. !
  63. !Changed 8/8/89 by DMC top not look for 2 ok's
  64. ClrMchStr
  65. MatchStr "5" "OK"
  66. MatchStr "6" "NO"         
  67. MatchStr "6" "ERROR"      
  68. MatchStr "6" ">"          { Special case for Avatex 1200 modems}
  69. MatchStr "3" "AT"
  70. !
  71. Pause 40                { Allow modem to settle between commands.}
  72. Xmit "ATQ0E0V1X1\0D"
  73. Wait 200                { wait for 'OK' from modem - fall thru if timeout }
  74. Jump "6"                  { Try lower baud rate...time out error on modem.}
  75. !
  76. -Label 3
  77. ClrMchStr
  78. MatchStr "5" "OK"
  79. Wait 200
  80. Jump "6"
  81. !
  82. -Label 5
  83. Exit 9600
  84. !
  85. !----------------------------------------------------------------------
  86. !
  87. !----------------------------------------------------------------------
  88. ! Check at 4800 Baud.
  89. !
  90. -LABEL 6                { wake up the modem }
  91. SerReset 4800 0 8 1
  92. Pause 30
  93. Flush
  94. !
  95. !                         
  96. ClrMchStr
  97. MatchStr "7" "OK"
  98. MatchStr "7" "NO"         
  99. MatchStr "7" "ERROR"      
  100. MatchStr "7" ">"          { Special case for Avatex 1200 modems}
  101. MatchStr "7" "+++"         
  102. !
  103. Pause 210               { Pause for 2 sec min gap }
  104. Xmit +++                { Get the modems attention}
  105. Wait 210                { Pause for 2 sec min gap }
  106. !
  107. -Label 7
  108. !Changed 8/8/89 by DMC top not look for 2 ok's
  109. ClrMchStr
  110. MatchStr "10" "OK"
  111. MatchStr "11" "NO"         
  112. MatchStr "11" "ERROR"      
  113. MatchStr "11" ">"         { Special case for Avatex 1200 modems}
  114. !Changed 8/8/89 by DMC top branch to 8 on finding AT
  115. MatchStr "8" "AT"
  116. !
  117. Pause 40                { Allow modem to settle between commands.}
  118. Xmit "ATQ0E0V1X1\0D"
  119. Wait 200                { wait for 'OK' from modem - fall thru if timeout }
  120. Jump "11"                 { Try lower baud rate...time out error on modem.}
  121. !
  122. -Label 8
  123. ClrMchStr
  124. MatchStr "10" "OK"
  125. Wait 200
  126. Jump "11"
  127. !
  128. !
  129. -Label 10
  130. Exit 4800
  131. !
  132. !----------------------------------------------------------------------
  133. !
  134. !
  135. !----------------------------------------------------------------------
  136. ! Check at 2400 Baud.
  137. !
  138. -LABEL 11               { wake up the modem }
  139. SerReset 2400 0 8 1
  140. Pause 30
  141. Flush
  142. !
  143. !                         
  144. ClrMchStr
  145. MatchStr "12" "OK"
  146. MatchStr "12" "NO"         
  147. MatchStr "12" "ERROR"     
  148. MatchStr "12" ">"          { Special case for Avatex 1200 modems}
  149. MatchStr "12" "+++"          
  150. !
  151. Pause 210               { Pause for 2 sec min gap }
  152. Xmit "+++"                { Get the modems attention}
  153. Wait 210                { Pause for 2 sec min gap }
  154. !
  155. -Label 12
  156. ClrMchStr
  157. MatchStr "13" "AT"
  158. MatchStr "16" "NO"         
  159. MatchStr "16" "ERROR"      
  160. MatchStr "16" ">"         { Special case for Avatex 1200 modems}
  161. ! Extra MatchStr for OK added... 
  162. ! If we get an ok at this point, all is well.
  163. MatchStr "15" "OK"
  164. !
  165. Pause 40                { Allow modem to settle between commands.}
  166. Xmit "ATQ0E0V1X1\0D"
  167. Wait 200                { wait for 'OK' from modem - fall thru if timeout }
  168. Jump "16"                 { Try lower baud rate...time out error on modem.}
  169. !
  170. -Label 13
  171. ClrMchStr
  172. MatchStr "15" "OK"
  173. Wait 200
  174. Jump "16"
  175. !
  176. !
  177. -Label 15
  178. Exit 2400
  179. !
  180. !----------------------------------------------------------------------
  181. !
  182. !
  183. !
  184. !----------------------------------------------------------------------
  185. ! Check at 1200 Baud.
  186. !
  187. -LABEL 16               { wake up the modem }
  188. SerReset 1200 0 8 1
  189. Pause 30
  190. Flush
  191. !
  192. !                         
  193. ClrMchStr
  194. MatchStr "17" "OK"
  195. MatchStr "17" "NO"         
  196. MatchStr "17" "ERROR"      
  197. MatchStr "17" ">"         { Special case for Avatex 1200 modems}
  198. MatchStr "17" "+++"          
  199. !
  200. Pause 210               { Pause for 2 sec min gap }
  201. Xmit "+++"                { Get the modems attention}
  202. Wait 210                { Pause for 2 sec min gap }
  203. !
  204. -Label 17
  205. ClrMchStr
  206. MatchStr "18" "AT"
  207. MatchStr "21" "NO"         
  208. MatchStr "21" "ERROR"      
  209. MatchStr "21" ">"         { Special case for Avatex 1200 modems}
  210. MatchStr "20" "OK"        {Got the ok, successfull sniff at 1200}
  211. !
  212. Pause 40                { Allow modem to settle between commands.}
  213. Xmit "ATQ0E0V1X1\0D"
  214. Wait 200                { wait for 'OK' from modem - fall thru if timeout }
  215. Jump "21"                 { Try lower baud rate...time out error on modem.}
  216. !
  217. -Lable 18
  218. ClrMchStr
  219. MatchStr "20" "OK"
  220. Wait 200
  221. Jump "21"
  222. !
  223. !
  224. -Label 20
  225. Exit 1200
  226. !
  227. !----------------------------------------------------------------------
  228. !
  229. !
  230. !----------------------------------------------------------------------
  231. ! Check at 300 Baud.
  232. !
  233. -LABEL 21                { wake up the modem }
  234. SerReset 300 0 8 1
  235. Pause 30
  236. Flush
  237. !
  238. !                         
  239. ClrMchStr
  240. MatchStr "22" "OK"
  241. MatchStr "22" "NO"         
  242. MatchStr "22" "ERROR"      
  243. MatchStr "22" ">"          { Special case for Avatex 1200 modems}
  244. MatchStr "22" "+++"          
  245. !
  246. Pause 210               { Pause for 2 sec min gap }
  247. Xmit "+++"                { Get the modems attention}
  248. Wait 210                { Pause for 2 sec min gap }
  249. !
  250. -Label 22
  251. ClrMchStr
  252. MatchStr "23" "AT"
  253. MatchStr "26" "NO"         
  254. MatchStr "26" "ERROR"      
  255. MatchStr "26" ">"         { Special case for Avatex 1200 modems}
  256. MatchStr "23" "OK"
  257. !
  258. Pause 40                { Allow modem to settle between commands.}
  259. Xmit "ATQ0E0V1X1\0D"
  260. Wait 200                { wait for 'OK' from modem - fall thru if timeout }
  261. Jump "26"                 { Try lower baud rate...time out error on modem.}
  262. !
  263. -Label 23
  264. ClrMchStr
  265. MatchStr "25" "OK"
  266. Wait 200
  267. Jump "26"
  268. !
  269. !
  270. -Label 25
  271. Exit 300
  272. !
  273. !----------------------------------------------------------------------
  274. !
  275. -Label 26         {generic}
  276. Talert "Please take the following steps:\0D\0D 1) Turn your modem off; then back on.\0D 2) Make sure that your modem and phone line are connected  correctly.\0D 3) Try again."
  277. !
  278. -Label 27
  279. Alert "35" "\0DIf the problem persists, call ~APPL customer service at ~ACUS."
  280. Exit -1
  281. !
  282. !
  283. !
  284. -Label 30         {User cancelled, just exit....}
  285. Exit -111
  286. !
  287. !
  288. *-Label 1
  289. *Exit 0
  290. !
  291. ###
  292.